[SPARK-29539][SQL] SHOW PARTITIONS should look up catalog/table like v2 commands#26198
[SPARK-29539][SQL] SHOW PARTITIONS should look up catalog/table like v2 commands#26198huaxingao wants to merge 2 commits intoapache:masterfrom
Conversation
|
@viirya |
viirya
left a comment
There was a problem hiding this comment.
This looks fine to me. Looks like loadTable can provide partitioning info so V2 implementation can also be implemented now? @cloud-fan @rdblue
The partitioning provided by |
|
|
||
| test("SHOW PARTITIONS") { | ||
| val sql1 = "SHOW PARTITIONS t1" | ||
| val sql2 = "SHOW PARTITIONS db1.t1" |
There was a problem hiding this comment.
Thanks @viirya for your review. The comment has been addressed.
|
Test build #112414 has finished for PR 26198 at commit
|
|
Test build #112436 has finished for PR 26198 at commit
|
|
the changes LGTM, let's fix the conflict |
157b755 to
248513c
Compare
|
Test build #112478 has finished for PR 26198 at commit
|
|
Conflicts fixed @viirya |
|
Thanks. Merging this to master! |
|
Thanks all for the help! |
What changes were proposed in this pull request?
Add ShowPartitionsStatement and make SHOW PARTITIONS go through the same catalog/table resolution framework of v2 commands.
Why are the changes needed?
It's important to make all the commands have the same table resolution behavior, to avoid confusing end-users.
Does this PR introduce any user-facing change?
Yes. When running SHOW PARTITIONS, Spark fails the command if the current catalog is set to a v2 catalog, or the table name specified a v2 catalog.
How was this patch tested?
Unit tests.